﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package Display.DialogUI {
    import flash.utils.*;
    import org.aswing.*;
    import Classes.*;
    import tool.*;
    import org.aswing.event.*;
    import Display.aswingui.*;

    public class OffsetDialogView extends GenericDialogView {

        public var capture:JButton;

        public function OffsetDialogView(_arg1:Dictionary){
            this.capture = new JButton("Capture!");
            super(_arg1, "click capture and roll over target", "click capture");
            textArea.setLayout(ASwingHelper.softBoxLayoutVertical);
            textArea.setPreferredHeight(-1);
            textArea.setMinimumHeight(20);
        }
        private function doCapture(_arg1:AWEvent):void{
            title.setText("Roll over target...");
            textArea.removeAll();
            textArea.append(new JLabel("1st thing you roll onto"));
            textArea.append(new JLabel("with children will capture"));
            textArea.append(ASwingHelper.verticalStrut(30));
            ASwingHelper.prepare(this, this.parent);
            OffsetEditor.captureMode = true;
        }
        override protected function createTitlePanel():JPanel{
            var _local1:JPanel;
            _local1 = ASwingHelper.makeSoftBoxJPanel(SoftBoxLayout.CENTER);
            _local1.append(ASwingHelper.horizontalStrut(30));
            _local1.append(this.capture);
            title = ASwingHelper.makeTextField("click capture and roll over target", EmbeddedArt.TITLE_FONT, m_titleFontSize, EmbeddedArt.titleColor);
            title.filters = EmbeddedArt.titleFilters;
            _local1.append(title);
            this.capture.addActionListener(this.doCapture, 0, true);
            return (_local1);
        }

    }
}//package Display.DialogUI 
